package com.shuyixiao.javan8nv1.model;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import java.time.LocalDateTime;

@TableName("workflows")
public class Workflow {
    @TableId
    private String id;
    @TableField
    private String name;
    @TableField
    private boolean active = false;
    @TableField
    private boolean archived = false;
    @TableField
    private String settings; // JSON 字符串
    @TableField
    private String versionId;
    @TableField
    private LocalDateTime createdAt;
    @TableField
    private LocalDateTime updatedAt;

    public Workflow() {}
    public Workflow(String name) { this.name = name; }
    public String getId() { return id; }
    public void setId(String id) { this.id = id; }
    public String getName() { return name; }
    public void setName(String name) { this.name = name; }
    public boolean isActive() { return active; }
    public void setActive(boolean active) { this.active = active; }
    public boolean isArchived() { return archived; }
    public void setArchived(boolean archived) { this.archived = archived; }
    public String getSettings() { return settings; }
    public void setSettings(String settings) { this.settings = settings; }
    public String getVersionId() { return versionId; }
    public void setVersionId(String versionId) { this.versionId = versionId; }
    public LocalDateTime getCreatedAt() { return createdAt; }
    public void setCreatedAt(LocalDateTime createdAt) { this.createdAt = createdAt; }
    public LocalDateTime getUpdatedAt() { return updatedAt; }
    public void setUpdatedAt(LocalDateTime updatedAt) { this.updatedAt = updatedAt; }
}
